//
//  FKAboutUsVC.m
//  WanTao
//
//  Created by Macbook Pro on 2019/3/26.
//  Copyright © 2019 Macbook Pro. All rights reserved.
//

#import "FKAboutUsVC.h"

@interface FKAboutUsVC ()

@property (nonatomic, weak) UIWebView *webView;

@end

@implementation FKAboutUsVC

- (void)viewDidLoad {
    [super viewDidLoad];
    
    self.title = @"关于我们";
    
    UIWebView *webView = [[UIWebView alloc] init];
    [self.view addSubview:webView];
    self.webView = webView;
    webView.backgroundColor = [UIColor whiteColor];
    [webView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.edges.offset(0);
    }];
    
    [self loadData];
}

- (void)viewWillDisappear:(BOOL)animated
{
    [super viewWillDisappear:animated];
    
    if ([SVProgressHUD isVisible]) {
        [SVProgressHUD dismiss];
    }
}

- (void)loadData
{
    [SVProgressHUD show];
    [FKHttpTool postWithSuffix:@"m=Home&c=Mine&a=about_us" param:nil success:^(FKBaseResult *result) {
        if (result.isSuccess) {
            [SVProgressHUD dismiss];
            [self.webView loadHTMLString:result.data[@"info"] baseURL:nil];
        }
    } failure:nil];
}


@end
